MulticoreResponseTimeMeasurements Sample
Description
This sample program runs a System Response Timer on different cores simultaneously.
Each core has its own timer and its own thread allocation memory to support the timer function. The core thread creates the timer and the necessary resources, and then waits for the main thread to initiate the test with a fast semaphore to synchronize all cores as closely as possible, though the test does not synchronize results.
Source Files
mSrtm.cpp
– gathers thread-level timer latencies (either as a Win32 or RTSS process) and prints out a summary and an optional histogram of results. The timer can also generate a sound on the speaker. This is a useful tool for measuring application-level response time latencies while the system is stressed by other activity, such as disk, network, and GUI IO, and/or heavy processing. Different hardware platforms can also be compared.mSrtm_funcs.cpp
– additional helper functionsmSrtm.h
– header File
Building the Sample
Build the sample as is. See Usage for additional options.
Running the Sample
Run the sample as is. See Usage for additional options.
Usage
mSrtm | mSrtm [/?] [/h] [/s] [/1] [/f] [c] seconds_to_sample
Options
/h = Display histogram (in addition to summary)
/s = Turn on sound (square wave driven by timer)
/1 = Use a 10 MS timer period (default is 1 MS)
/f = Use fastest available timer (1MS or better)
/c = Use RtGetClockTime to measure
/? = help on usage
If no parameters given, default is mSrtm /h /s /f 15
, and timing is done on all RTSS threads
Remarks
The mSRTM program can be built as a Win32 .exe or real-time .rtss executable file.
The mSRTM program differs from the SRTM program in that mSRTM measures the timer periodic interval deviation from the set value, while SRTM measures the timer response latencies including APIC timer drift.
APIs Referenced
RTAPI | Windows APIs |
---|---|
RtEnablePortIo |